$(function () {
   // 垂直滚动
   $(function () {
    $('.comments').liMarquee({
        direction: 'down',
    });
});
    function myChart2_1() {

        var myChart = echarts.init(document.getElementById('chart2-1'));
        var dataName = ['小程序', 'OTA', '旅行社', '线下售票'];

        var dataName2 = ['小程序', 'OTA', '旅行社', '线下售票'];
        var value = [12, 10, 5, 7]
        var dataarr = []
        var max = value[0];
        var dataarr2 = []
        value.forEach(function (ele, index) {
            if (ele > max) {
                max = ele;
            }
            dataarr.push({
                value: ele,
                name: dataName[index]
            })
            dataarr2.push({
                value: ele,
                name: dataName2[index]
            })
        })


        option = {
            title: {
                text: '推广占比',
                left:'center',
                y:'45%',
                textStyle: {
                    color: '#fff',
                    fontSize: 14
                },
               
            },
            tooltip: {
                trigger: 'item',
                formatter: "{a} <br/>{b}: {c} ({d}%)",

            },
            legend: {

                orient: 'vertical',
                x: 'right',
                y: '10%',
                itemWidth: 14,
                itemGap: 10,
                itemHeight: 8,
                align: 'left',

                data: dataName,
                textStyle: {
                    color: '#fff',
                    fontSize: 12
                }
            },
            series: [{
                name: '访问来源',
                type: 'pie',
                center: ['50%', '50%'],
                radius: ['40%', '75%'],
                color: [
                    '#2CEDED',
                    '#7049F0',
                    '#B347FF',
                    '#E70E65',
                ],
                label: {
                    normal: {
                        show: false,
                        formatter: '{b}\n{d}%',
                        fontSize: 16,
                    },

                },
                labelLine: {
                    normal: {
                        show: false,
                        length: 10,
                        length2: 74
                    }
                },
                data: dataarr
            }]
        };

        myChart.setOption(option);
    }
    function myChart2_2() {

        var myChart = echarts.init(document.getElementById('chart2-2'));
        option = {
            grid: {
                top: "23%",
                bottom: "12%",
                left: "12%",
                right: "15%"
            },
            tooltip: {
                trigger: "axis",
                axisPointer: {
                    type: "shadow",
                    label: {
                        show: true
                    }
                }
            },
            xAxis: {
                data: [
                    "美团",
                    "携程",
                    "飞猪"
                ],
                axisLine: {
                    show: true //隐藏X轴轴线
                },
                axisTick: {
                    show: false //隐藏X轴刻度
                },
                axisLabel: {
                    show: true,
                    textStyle: {
                        color: "#657CA8" //X轴文字颜色
                    }
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,0.3)'
                    }
                },
            },
            yAxis: [{
                type: "value",
                name: "(数量)",
                min: 0,
                max: 500,
                splitNumber: 5,

                nameTextStyle: {
                    color: "#fff"
                },
                splitLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLine: {
                    show: true
                },
                axisLabel: {
                    show: true,
                    textStyle: {
                        color: "#657CA8"
                    }
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,0.3)'
                    }
                },
            },
            {
                type: "value",
                name: "(元)",
                min: 0,
                max: 5000,
                splitNumber: 5,
                splitLine: {
                    show: false
                },
                nameTextStyle: {
                    color: "#fff"
                },
                position: "right",
                splitLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLine: {
                    show: true
                },
                axisLabel: {
                    show: true,
                    formatter: "{value}", //右侧Y轴文字显示
                    textStyle: {
                        color: "#657CA8"
                    }
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,0.3)'
                    }
                },
            },
            ],
            series: [{
                name: "金额",
                type: "line",
                yAxisIndex: 1, //使用的 y 轴的 index，在单个图表实例中存在多个 y轴的时候有用
                smooth: true, //平滑曲线显示
                showAllSymbol: true, //显示所有图形。
                symbol: "none", //标记的图形为实心圆
                itemStyle: {
                    //折线拐点标志的样式
                    color: "#058cff",

                },
                lineStyle: {
                    color: "#FFAD45"
                },

                data: [4800, 3200, 4800]
            },
            {
                name: "数量",
                type: "bar",
                barWidth: 15,
                itemStyle: {
                    normal: {
                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                            offset: 0,
                            color: "#04DEAF"
                        },
                        {
                            offset: 1,
                            color: "#00D98B"
                        }
                        ]),
                        barBorderRadius: [30, 30, 0, 0],
                    }
                },
                data: [500, 340, 500]
            }
            ]
        };

        myChart.setOption(option);
    }
    function myChart2_3() {

        var myChart = echarts.init(document.getElementById('chart2-3'));
        var dataName = ['酒店', '景区', '餐饮店', '旅行社', '商家'];

        var dataName2 = ['酒店', '景区', '餐饮店', '旅行社', '商家'];
        var value = [7, 10, 5, 18, 4]
        var dataarr = []
        var max = value[0];
        var dataarr2 = []
        value.forEach(function (ele, index) {
            if (ele > max) {
                max = ele;
            }
            dataarr.push({
                value: ele,
                name: dataName[index]
            })
            dataarr2.push({
                value: ele,
                name: dataName2[index]
            })
        })


        option = {
            title: {
                text: '投诉占比',
                left:"center",
                y: '45%',
                textStyle: {
                    color: '#fff',
                    fontSize: 14,
                },
               
            },
            tooltip: {
                trigger: 'item',
                formatter: "{a} <br/>{b}: {c} ({d}%)",

            },
            legend: {

                orient: 'vertical',
                x: 'right',
                y: '10%',
                itemWidth: 14,
                itemGap: 10,
                itemHeight: 8,
                align: 'left',

                data: dataName,
                textStyle: {
                    color: '#fff',
                    fontSize: 12
                }
            },
            series: [{
                name: '访问来源',
                type: 'pie',
                center: ['50%', '50%'],
                radius: ['40%', '75%'],
                color: [
                    '#08DECD',
                    '#FFAD45',
                    '#238FCD',
                    '#01DB99',
                    '#F35777'
                ],
                label: {
                    normal: {
                        show: false,
                        formatter: '{b}\n{d}%',
                        fontSize: 16
                    },

                },
                labelLine: {
                    normal: {
                        show: false,
                        length: 10,
                        length2: 74
                    }
                },
                data: dataarr
            }]
        };

        myChart.setOption(option);
    }
    function myChart2_4_1() {
       
        var myChart = echarts.init(document.getElementById('chart2-4-1'));
        option = {
            grid: {
                top: "25%",
                bottom: "10%",
                left: "13%",
                right: "13%"
            },
            // tooltip（提示框组件）
            tooltip: {
                //trigger(触发类型)，可选'item','axis','none'
                trigger: 'axis',
                axisPointer: {
                    //指示器类型,可选'line','shadow','cross'
                    type: 'shadow'
                },


                formatter: '{a0}：{c0}<br/>{a1}：{c1}<br/>{a2}：{c2}%',
            },
            legend: {
                top: "5%",
                right: "0",
                itemWidth: 14,
                itemHeight: 8,
                name: ['销售量', '金额', '占比'],
                textStyle: {
                    fontSize: 12,
                    color: '#fff',
                },
            },
            xAxis: {
                type: 'category',
                //axisTick 坐标轴刻度相关设置
                axisTick: {
                    show: false
                },
                //axixLine 坐标轴轴线相关设置
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,1)',
                    }
                },
                data: ['小程序', 'OTA', '旅行社', '线下售票'],
                //axisLabel 坐标轴刻度标签的相关设置
                axisLabel: {
                    // show: true,
                    color: '#657CA8',
                    fontSize: 12,
                }
            },
            yAxis: [{
                name: '(数量)',
                type: 'value',
                min: 0,
                max: 5000,
                splitNumber: 5,
                nameTextStyle: {
                    color: '#fff'
                },
                axisLabel: {
                    show: true,
                    color: '#657CA8',
                    fontSize: 12,
                    formatter: '{value}',
                },
                splitLine: {
                    show: false
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,0.3)'
                    }
                },
                axisTick: {
                    // show: false
                },
            }, {
                name: '占比',
                type: 'value',
                position: 'right',
                min: 0,
                max: 100,
                splitNumber: 5,
                nameTextStyle: {
                    color: '#fff'
                },
                axisLabel: {
                    show: true,
                    color: '#657CA8',
                    fontSize: 12,
                    formatter: '{value}%',
                },
                splitLine: {
                    show: false
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,1)'
                    }
                },
                axisTick: {
                    // show: false
                },
            }
            ],
            series: [{
                name: '销售量',
                //type决定图表类型
                type: 'bar',
                data: [4000, 3600, 2500, 4300],
                barWidth: '20%',
                itemStyle: {
                    color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                        offset: 0,
                        color: "#07E2CD"
                    },
                    {
                        offset: 1,
                        color: "#2782CD"
                    }
                    ]),
                    barBorderRadius: [30, 30, 0, 0]
                }
            }, {
                name: '占比',
                //type决定图表类型
                type: 'bar',
                data: [4800, 4200, 3200, 4900],
                barWidth: '20%',
                itemStyle: {
                    color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                        offset: 0,
                        color: "#65B0FF"
                    },
                    {
                        offset: 1,
                        color: "#1C79DA"
                    }
                    ]),
                    barBorderRadius: [30, 30, 0, 0]
                }
            }, {
                name: '金额',
                //type决定图表类型
                type: 'line',
                smooth: true,
                symbol: 'none',
                yAxisIndex: 1,
                data: [99, 55, 24, 65],
                itemStyle: {
                    color: '#FFAD45',
                },
                areaStyle: {
                    normal: {
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 0, 1, [{
                                offset: 0,
                                color: 'rgba(247,172,86,0.4)'
                            },
                            {
                                offset: 1,
                                color: 'rgba(255,255,255,0.2)'
                            }
                            ])
                    }
                }
            }
            ]
        };
        myChart.setOption(option);
    }
    function myChart2_4_2() {
       
        var myChart = echarts.init(document.getElementById('chart2-4-2'));
        option = {
            grid: {
                top: "25%",
                bottom: "10%",
                left: "13%",
                right: "13%"
            },
            // tooltip（提示框组件）
            tooltip: {
                //trigger(触发类型)，可选'item','axis','none'
                trigger: 'axis',
                axisPointer: {
                    //指示器类型,可选'line','shadow','cross'
                    type: 'shadow'
                },


                formatter: '{a0}：{c0}<br/>{a1}：{c1}<br/>{a2}：{c2}%',
            },
            legend: {
                top: "5%",
                right: "0",
                itemWidth: 14,
                itemHeight: 8,
                name: ['销售量', '金额', '占比'],
                textStyle: {
                    fontSize: 12,
                    color: '#fff',
                },
            },
            xAxis: {
                type: 'category',
                //axisTick 坐标轴刻度相关设置
                axisTick: {
                    show: false
                },
                //axixLine 坐标轴轴线相关设置
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,1)',
                    }
                },
                data: ['小程序', 'OTA', '旅行社', '线下售票'],
                //axisLabel 坐标轴刻度标签的相关设置
                axisLabel: {
                    // show: true,
                    color: '#657CA8',
                    fontSize: 12,
                }
            },
            yAxis: [{
                name: '(数量)',
                type: 'value',
                min: 0,
                max: 5000,
                splitNumber: 5,
                nameTextStyle: {
                    color: '#fff'
                },
                axisLabel: {
                    show: true,
                    color: '#657CA8',
                    fontSize: 12,
                    formatter: '{value}',
                },
                splitLine: {
                    show: false
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,0.3)'
                    }
                },
                axisTick: {
                    // show: false
                },
            }, {
                name: '占比',
                type: 'value',
                position: 'right',
                min: 0,
                max: 100,
                splitNumber: 5,
                nameTextStyle: {
                    color: '#fff'
                },
                axisLabel: {
                    show: true,
                    color: '#657CA8',
                    fontSize: 12,
                    formatter: '{value}%',
                },
                splitLine: {
                    show: false
                },
                axisLine: {
                    lineStyle: {
                        color: 'rgba(101,124,168,1)'
                    }
                },
                axisTick: {
                    // show: false
                },
            }
            ],
            series: [{
                name: '销售量',
                //type决定图表类型
                type: 'bar',
                data: [3000, 3600, 4500, 4300],
                barWidth: '20%',
                itemStyle: {
                    color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                        offset: 0,
                        color: "#07E2CD"
                    },
                    {
                        offset: 1,
                        color: "#2782CD"
                    }
                    ]),
                    barBorderRadius: [30, 30, 0, 0]
                }
            }, {
                name: '占比',
                //type决定图表类型
                type: 'bar',
                data: [3800, 4600, 3000, 5000],
                barWidth: '20%',
                itemStyle: {
                    color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                        offset: 0,
                        color: "#65B0FF"
                    },
                    {
                        offset: 1,
                        color: "#1C79DA"
                    }
                    ]),
                    barBorderRadius: [30, 30, 0, 0]
                }
            }, {
                name: '金额',
                //type决定图表类型
                type: 'line',
                smooth: true,
                symbol: 'none',
                yAxisIndex: 1,
                data: [90, 65, 34, 65],
                itemStyle: {
                    color: '#FFAD45',
                },
                areaStyle: {
                    normal: {
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 0, 1, [{
                                offset: 0,
                                color: 'rgba(247,172,86,0.4)'
                            },
                            {
                                offset: 1,
                                color: 'rgba(255,255,255,0.2)'
                            }
                            ])
                    }
                }
            }
            ]
        };
        myChart.setOption(option);
    }
    function myChart2_5_1() {

        var myChart = echarts.init(document.getElementById('chart2-5-1'));
        option = {
            title: {
                text: '舆论正负占比',
                textStyle: {
                    fontSize: 14,
                    color: "#fff"
                },
                left: "2%",
                top: '5%'
            },
            tooltip: {
                trigger: 'item',
                formatter: function (parms) {
                    var str = parms.seriesName + "</br>" +
                        parms.marker + "" + parms.data.legendname + "</br>" +
                        "数量：" + parms.data.value + "</br>" +
                        "占比：" + parms.percent + "%";
                    return str;
                }
            },

            series: [
                {
                    name: '舆论正负占比',
                    type: 'pie',
                    center: ['48%', '50%'],
                    radius: ['35%', '55%'],
                    clockwise: false, //饼图的扇区是否是顺时针排布
                    avoidLabelOverlap: false,
                    label: {
                        normal: {
                            show: true,
                            position: 'outter',
                            rich: {
                                a: {
                                    fontSize: 14,
                                    fontWeight: 600,
                                    padding: [5, 0]
                                },
                                b: {
                                    width: '100%',
                                    height: 0,
                                    borderColor: 'rgba(101,124,168,1)',
                                    borderWidth: 0.5,

                                },
                                c: {
                                    padding: [5, 0]
                                }
                            },
                            formatter: function (parms) {
                                return '{a|' + parms.data.value + '} 人' + '\n' + '{b|}' + '\n' + '{c|' + parms.data.legendname + '}'
                            },

                        }
                    },
                    labelLine: {
                        normal: {
                            length: 20,
                            length2: 20,
                            smooth: false,
                        }
                    },
                    data: [{ value: 1522, legendname: '正面', itemStyle: { color: "#FFAD45" } },
                    { value: 123, legendname: '负面', itemStyle: { color: "#08DECD" } },]
                }
            ]
        };

        myChart.setOption(option);
    }
    function myChart2_5_2() {

        var myChart = echarts.init(document.getElementById('chart2-5-2'));
        option = {
            title: {
                text: '舆论传播渠道占比',
                textStyle: {
                    fontSize: 14,
                    color: "#fff"
                },
                left: "2%",
                top: '5%'
            },
            color: ['#238FCD', '#F35777', '#FFAD45', '#01DB99'],
            tooltip: {
                trigger: 'item',
                formatter: "{a} <br/>{b} : {c} ({d}%)"
            },

            calculable: true,
            series: [
                {
                    name: '舆论传播渠道占比',
                    type: 'pie',
                    center: ['47%', '55%'],
                    radius: [25, 80],
                    roseType: 'area',
                    label: {
                        normal: {

                            formatter: (params) => {
                                return params.data.name + ':' + params.data.value + '%'
                            }
                        }


                    },
                    data: [
                        { value: 15, name: '互联网' },
                        { value: 30, name: 'QQ' },
                        { value: 15, name: '微博' },
                        { value: 25, name: '微信' },

                    ]
                }
            ]
        };

        myChart.setOption(option);
    }
    function myChart2_5_3() {

        var myChart = echarts.init(document.getElementById('chart2-5-3'));
        option = {
            title: {
                text: '舆论正负占比',
                textStyle: {
                    fontSize: 14,
                    color: "#fff"
                },
                left: "2%",
                top: '5%'
            },
            tooltip: {
                trigger: 'item',
                formatter: function (parms) {
                    var str = parms.seriesName + "</br>" +
                        parms.marker + "" + parms.data.legendname + "</br>" +
                        "数量：" + parms.data.value + "</br>" +
                        "占比：" + parms.percent + "%";
                    return str;
                }
            },

            series: [
                {
                    name: '舆论正负占比',
                    type: 'pie',
                    center: ['48%', '50%'],
                    radius: ['35%', '55%'],
                    clockwise: false, //饼图的扇区是否是顺时针排布
                    avoidLabelOverlap: false,
                    label: {
                        normal: {
                            show: true,
                            position: 'outter',
                            rich: {
                                a: {
                                    fontSize: 14,
                                    fontWeight: 600,
                                    padding: [5, 0]
                                },
                                b: {
                                    width: '100%',
                                    height: 0,
                                    borderColor: 'rgba(101,124,168,1)',
                                    borderWidth: 0.5,

                                },
                                c: {
                                    padding: [5, 0]
                                }
                            },
                            formatter: function (parms) {
                                return '{a|' + parms.data.value + '} 人' + '\n' + '{b|}' + '\n' + '{c|' + parms.data.legendname + '}'
                            },

                        }
                    },
                    labelLine: {
                        normal: {
                            length: 20,
                            length2: 20,
                            smooth: false,
                        }
                    },
                    data: [{ value: 1800, legendname: '正面', itemStyle: { color: "#FFAD45" } },
                    { value: 60, legendname: '负面', itemStyle: { color: "#08DECD" } },]
                }
            ]
        };

        myChart.setOption(option);
    }
    function myChart2_5_4() {

        var myChart = echarts.init(document.getElementById('chart2-5-4'));
        option = {
            title: {
                text: '舆论传播渠道占比',
                textStyle: {
                    fontSize: 14,
                    color: "#fff"
                },
                left: "2%",
                top: '5%'
            },
            color: ['#238FCD', '#F35777', '#FFAD45', '#01DB99'],
            tooltip: {
                trigger: 'item',
                formatter: "{a} <br/>{b} : {c} ({d}%)"
            },

            calculable: true,
            series: [
                {
                    name: '舆论传播渠道占比',
                    type: 'pie',
                    center: ['47%', '55%'],
                    radius: [25, 80],
                    roseType: 'area',
                    label: {
                        normal: {

                            formatter: (params) => {
                                return params.data.name + ':' + params.data.value + '%'
                            }
                        }


                    },
                    data: [
                        { value: 18, name: '互联网' },
                        { value: 35, name: 'QQ' },
                        { value: 16, name: '微博' },
                        { value: 25, name: '微信' },

                    ]
                }
            ]
        };

        myChart.setOption(option);
    }
    function myChart_stars5() {

        var myChart = echarts.init(document.getElementById('stars5'));
        var data = [85]
        var titlename = ['景区'];
        var valdata = [3500]
        option = {
            grid: {
                left: '15%',
                right: '18%',
            },
            xAxis: {
                show: false
            },
            yAxis: [{
                show: true,
                data: titlename,
                inverse: true,
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLabel: {
                    color: '#00CCFF',
                },


            }, {
                show: true,
                inverse: true,
                data: valdata,
                axisLabel: {
                    formatter:valdata+'条',
                    textStyle: {
                        fontSize: 12,
                        color: '#fff',
                    },
                },
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },

            }],
            series: [{
                type: 'bar',
                yAxisIndex: 0,
                data: data,
                barWidth: 10,
                itemStyle: {
                    normal: {
                        barBorderRadius: 4,
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 1, 0, [{
                                    offset: 0,
                                    color: '#2782CD'
                                },
                                {
                                    offset: 1,
                                    color: '#07E2CD'
                                }
                            ])
                    }
                },
                label: {
                    normal: {
                        show: true,
                        position: 'inside',
                        formatter: '{c}%',
                        textStyle: {
                            fontSize: 12,
                            color: '#fff'
                        }
                    }
                },
            }, {
                name: '框',
                type: 'bar',
                yAxisIndex: 1,
                barGap: '-100%',
                data: [100],
                barWidth: 16,
                itemStyle: {
                    normal: {
                        color: 'none',
                        borderColor: 'rgba(73,226,235,0.2)',
                        borderWidth: 1,
                        barBorderRadius: 4,
                    }
                }
            },]
        };

        myChart.setOption(option);
    }
    function myChart_stars4() {

        var myChart = echarts.init(document.getElementById('stars4'));
        var data = [75]
        var titlename = ['美食'];
        var valdata = [2854]
        option = {
            grid: {
                left: "15%",
                right: "18%"
            },
            xAxis: {
                show: false
            },
            yAxis: [{
                show: true,
                data: titlename,
                inverse: true,
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLabel: {
                    color: '#00CCFF',
                },


            }, {
                show: true,
                inverse: true,
                data: valdata,
                axisLabel: {
                    formatter:valdata+'条',
                    textStyle: {
                        fontSize: 12,
                        color: '#fff',
                    },
                },
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },

            }],
            series: [{
                name: '条',
                type: 'bar',
                yAxisIndex: 0,
                data: data,
                barWidth: 10,
                itemStyle: {
                    normal: {
                        barBorderRadius: 4,
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 1, 0, [{
                                    offset: 0,
                                    color: '#2782CD'
                                },
                                {
                                    offset: 1,
                                    color: '#07E2CD'
                                }
                            ])
                    }
                },
                label: {
                    normal: {
                        show: true,
                        position: 'inside',
                        formatter: '{c}%',
                        textStyle: {
                            fontSize: 12,
                            color: '#fff'
                        }
                    }
                },
            }, {
                name: '框',
                type: 'bar',
                yAxisIndex: 1,
                barGap: '-100%',
                data: [100],
                barWidth: 16,
                itemStyle: {
                    normal: {
                        color: 'none',
                        borderColor: 'rgba(73,226,235,0.2)',
                        borderWidth: 1,
                        barBorderRadius: 4,
                    }
                }
            },]
        };

        myChart.setOption(option);
    }
    function myChart_stars3() {

        var myChart = echarts.init(document.getElementById('stars3'));
        var data = [65]
        var titlename = ['餐饮'];
        var valdata = [1956]
        option = {
            grid: {
                left: "15%",
                right: "18%"
            },
            xAxis: {
                show: false
            },
            yAxis: [{
                show: true,
                data: titlename,
                inverse: true,
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLabel: {
                    color: '#00CCFF',
                },


            }, {
                show: true,
                inverse: true,
                data: valdata,
                axisLabel: {
                    formatter:valdata+'条',
                    textStyle: {
                        fontSize: 12,
                        color: '#fff',
                    },
                },
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },

            }],
            series: [{
                name: '条',
                type: 'bar',
                yAxisIndex: 0,
                data: data,
                barWidth: 10,
                itemStyle: {
                    normal: {
                        barBorderRadius: 4,
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 1, 0, [{
                                    offset: 0,
                                    color: '#2782CD'
                                },
                                {
                                    offset: 1,
                                    color: '#07E2CD'
                                }
                            ])
                    }
                },
                label: {
                    normal: {
                        show: true,
                        position: 'inside',
                        formatter: '{c}%',
                        textStyle: {
                            fontSize: 12,
                            color: '#fff'
                        }
                    }
                },
            }, {
                name: '框',
                type: 'bar',
                yAxisIndex: 1,
                barGap: '-100%',
                data: [100],
                barWidth: 16,
                itemStyle: {
                    normal: {
                        color: 'none',
                        borderColor: 'rgba(73,226,235,0.2)',
                        borderWidth: 1,
                        barBorderRadius: 4,
                    }
                }
            },]
        };

        myChart.setOption(option);
    }
    function myChart_stars2() {

        var myChart = echarts.init(document.getElementById('stars2'));
        var data = [46]
        var titlename = ['购物'];
        var valdata = [1756]
        option = {
            grid: {
                left: "15%",
                right: "18%"
            },
            xAxis: {
                show: false
            },
            yAxis: [{
                show: true,
                data: titlename,
                inverse: true,
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLabel: {
                    color: '#00CCFF',
                },


            }, {
                show: true,
                inverse: true,
                data: valdata,
                axisLabel: {
                    formatter:valdata+'条',
                    textStyle: {
                        fontSize: 12,
                        color: '#fff',
                    },
                },
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },

            }],
            series: [{
                name: '条',
                type: 'bar',
                yAxisIndex: 0,
                data: data,
                barWidth: 10,
                itemStyle: {
                    normal: {
                        barBorderRadius: 4,
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 1, 0, [{
                                    offset: 0,
                                    color: '#2782CD'
                                },
                                {
                                    offset: 1,
                                    color: '#07E2CD'
                                }
                            ])
                    }
                },
                label: {
                    normal: {
                        show: true,
                        position: 'inside',
                        formatter: '{c}%',
                        textStyle: {
                            fontSize: 12,
                            color: '#fff'
                        }
                    }
                },
            }, {
                name: '框',
                type: 'bar',
                yAxisIndex: 1,
                barGap: '-100%',
                data: [100],
                barWidth: 16,
                itemStyle: {
                    normal: {
                        color: 'none',
                        borderColor: 'rgba(73,226,235,0.2)',
                        borderWidth: 1,
                        barBorderRadius: 4,
                    }
                }
            },]
        };

        myChart.setOption(option);
    }
    function myChart_stars1() {

        var myChart = echarts.init(document.getElementById('stars1'));
        var data = [22]
        var titlename = ['娱乐'];
        var valdata = [1002]
        option = {
            grid: {
                left: "15%",
                right: "18%"
            },
            xAxis: {
                show: false
            },
            yAxis: [{
                show: true,
                data: titlename,
                inverse: true,
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },
                axisLabel: {
                    color: '#00CCFF',
                },


            }, {
                show: true,
                inverse: true,
                data: valdata,
                axisLabel: {
                    formatter:valdata+'条',
                    textStyle: {
                        fontSize: 12,
                        color: '#fff',
                    },
                },
                axisLine: {
                    show: false
                },
                splitLine: {
                    show: false
                },
                axisTick: {
                    show: false
                },

            }],
            series: [{
                name: '条',
                type: 'bar',
                yAxisIndex: 0,
                data: data,
                barWidth: 10,
                itemStyle: {
                    normal: {
                        barBorderRadius: 4,
                        color: new echarts.graphic.LinearGradient(
                            0, 0, 1, 0, [{
                                    offset: 0,
                                    color: '#2782CD'
                                },
                                {
                                    offset: 1,
                                    color: '#07E2CD'
                                }
                            ])
                    }
                },
                label: {
                    normal: {
                        show: true,
                        position: 'inside',
                        formatter: '{c}%',
                        textStyle: {
                            fontSize: 12,
                            color: '#fff'
                        }
                    }
                },
            }, {
                name: '框',
                type: 'bar',
                yAxisIndex: 1,
                barGap: '-100%',
                data: [100],
                barWidth: 16,
                itemStyle: {
                    normal: {
                        color: 'none',
                        borderColor: 'rgba(73,226,235,0.2)',
                        borderWidth: 1,
                        barBorderRadius: 4,
                    }
                }
            },]
        };

        myChart.setOption(option);
    }
   
    myChart2_1();
    myChart2_2();
    myChart2_3();
    myChart2_4_1();
    myChart2_4_2();
    myChart2_5_1();
    myChart2_5_2();
    myChart2_5_3();
    myChart2_5_4();
    myChart_stars5();
    myChart_stars4();
    myChart_stars3();
    myChart_stars2();
    myChart_stars1();
     // 中间部分tab栏点击
     $('.center-tap>a').click(function(){
        $(this).addClass('active').siblings().removeClass('active')
        let index=$(this).index()
        $('.center-tab-item:eq('+index+')').removeClass('chart-hd').siblings().addClass('chart-hd')
    })
})